package com.monster.dict.infrastructure.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.gitee.sunchenbin.mybatis.actable.annotation.Column;
import com.gitee.sunchenbin.mybatis.actable.annotation.DefaultValue;
import com.gitee.sunchenbin.mybatis.actable.annotation.TableComment;
import com.gitee.sunchenbin.mybatis.actable.annotation.Unique;
import com.monster.starter.core.common.entity.BaseEntity;
import lombok.Data;

/**
 * 系统枚举项表
 * @author kuang
 */
@Data
@TableName
@TableComment("枚举信息子表")
public class SysDictItem extends BaseEntity {
    @TableField
    @Unique(columns = {"code","dict_code"})
    @Column(length = 32, isNull = false, comment = "枚举编码")
    private String code;
    @TableField
    @Column(length = 50, isNull = false, comment = "枚举值")
    private String value;
    @TableField
    @Column(length = 50, isNull = false, comment = "枚举名称")
    private String name;
    @TableField
    @Column(length = 32, isNull = false, comment = "枚举主表的code")
    private String dictCode;
    @TableField
    @DefaultValue("0")
    @Column(length = 1, isNull = false, comment = "是否固定 0：解锁；1：锁定")
    private Integer lockState;
    @TableField
    @Column(length = 150, comment = "字典详细描述")
    private String detail;
    @TableField
    @DefaultValue("1")
    @Column(length = 1, isNull = false, comment = "字典状态 0：禁用；1：启用")
    private Integer state;
}
